//
//  commonVariable.swift
//  压岁_IOS
//
//  Created by 梓简王 on 2017/7/12.
//  Copyright © 2017年 梓简王. All rights reserved.
//

import UIKit
import Foundation
import SlideMenuControllerSwift
class commonVariable: NSObject {
    //是否为测试
    static let ISCHECK = false
    //屏幕中心
    static let WINDOWSCENTER = CGPoint(x: commonVariable.SYSTEM_WIDTH/2, y: commonVariable.SYSTEM_HEIGHT/2)
    //获取系统的长宽
    static let SYSTEM_HEIGHT = UIScreen.mainScreen().bounds.height
    static let SYSTEM_WIDTH = UIScreen.mainScreen().bounds.width
    //首部位置
    static var HEADERPOSITION = CGRect(x: 0, y: 0, width: commonVariable.SYSTEM_WIDTH, height: 66)
    //背景颜色
    static let BACKGROUNDCOLOR = commonTool.getColorWithRGB(242, green: 249, blue: 253, alpha: 1)
    //数字键盘
    static let NUMPAD = WLDecimalKeyboard()
    //用户模型
    static var LOCAL_USER:User? = User()
    //普通账户模型
    static var COMMONACCOUNT:commonAccount? = commonAccount()
    //蓝色
    static let BLUECOLOR = UIColor.init(red: 0.000, green: 0.294, blue: 0.624, alpha: 1.000)
    //铁灰
    static let IRONCOLOR = commonTool.getColorWithRGB(87, green: 101, blue: 118, alpha: 1)
    //深红
    static let DEEPREDCOLOR = commonTool.getColorWithRGB(211, green: 56, blue: 53, alpha: 1)
    //爸爸的颜色
    static let PAPACOLOR = commonTool.getColorWithRGB(87, green: 191, blue: 168, alpha: 1.0)
    //妈妈的颜色
    static let MAMACOLOR = commonTool.getColorWithRGB(241, green: 150, blue: 166, alpha: 1.0)
    //儿子的颜色
    static let BABYCOLOR = commonTool.getColorWithRGB(120, green: 181, blue: 82, alpha: 1.0)
    //用户未绑定时的提示
    static let NOTFORNOTBAND = "请先绑定Ta的账户"
    //主页两边图标的透明度
    static let ICONALPH:CGFloat = 0.4
    //Host页面对象
    static var HOSTCLASS:SlideMenuController?
    //登录界面对象
    static var LOGINVIEW:loginViewController?
    //用户信息左列表
    static var USERLIST:userListController?
    //用户主页面滑动模块 
    static var RECORDERCONTROLLER:recordController?
    //用户修改信息界面
    static var USERINFOCLASS:meInfoController?
    //开发者信息
    static var DEVELOPINFOCLASS:setDetailShowViewControl?
    //用户建议
    static var USERSUGGESTION:suggestViewController?
    //用户滑动模块当前显示界面
    static var CURRENTPAGE:Int = 0
    //用户信息存储位置
    static var USERINFOPATH:String = (NSHomeDirectory() + "/Documents/userInfo.plist")
    //账户信息
    static var ACCOUNTPATH:String = (NSHomeDirectory() + "/Documents/account.plist")
    //学校Plist存储地址
    static var SCHOOLINFOPATH:String = (NSHomeDirectory() + "/Documents/school.plist")
    //主页头像位置
    static var USERHEADERPOSTION:CGRect = CGRect(x: 0, y: 50, width: commonVariable.ROOTVIEWHEIGTH, height: commonVariable.ROOTVIEWHEIGTH)
    //主页根角色与子角色大小
    static var ROOTVIEWHEIGTH:Int = 150
    static var CHILDVIEWHEIGTH:Int = 75
    //字体名字
    static var CHINAFONTNAME = "BigruiqiaoGB1.0"
    static var ENGLISHFONTNAME = "LoveLight"
    static var NUMBERFONTNAME = "Daniel Black"
    //主页DataSource
    static var pageCount: [Int] = [0,1]
    static var pageData: [String] = ["0","-1"]
    static var pageMoney: [String] = ["10000",commonVariable.NOTFORNOTBAND]
    //时间线数据
    static var TIMELINE_CENTERPOINT_HEIGHT:Int = 15
    static var TIMELINE_CENTERPOINT_COLOR:UIColor = commonTool.getColorWithRGB(54, green: 233, blue: 0, alpha: 1)
    static var TIMELINE_LINE_WIDTH = 2
    static var TIMELINE_LINE_COLOR = commonTool.getColorWithRGB(68, green: 77, blue: 89, alpha: 1)
    static var CELL_HEIGHT:Int = 44
    static var TIMELINE_HEADER_WEIGTH = 30
    //主页弹出框大小
    static var HOST_POPVIEW_HEIGHT = commonVariable.SYSTEM_HEIGHT * 2/5
    static var HOST_POPVIEW_WEIGHT = commonVariable.SYSTEM_WIDTH * 3/4
    //加载控制器
    static let LOADING_PACMAN = NVActivityIndicatorView(frame: CGRect(x: 0, y: 0, width: commonVariable.SYSTEM_WIDTH/3, height: commonVariable.SYSTEM_WIDTH/3), type: NVActivityIndicatorType.Pacman, color: commonVariable.BLUECOLOR)
    //操作数组
    static var accountArr:[commonAccountRecord] = []
    //接口 giftmoney
//    static var HOSTIP = "http://139.129.18.51:8080"
//    static var HOSTIP = "http://192.168.1.142:8080"
    static var HOSTIP = "http://giftmoney.dpgeek.cn:8080"
    static var USERREGISTERATION = "\(commonVariable.HOSTIP)/money/controller/ws/userRegisteration"
    static var USERLOGIN = "\(commonVariable.HOSTIP)/money/controller/ws/userLogin"
    static var EDITUSERINFO = "\(commonVariable.HOSTIP)/money/controller/ws/editUserInfo"
    static var EDITUSERPASS = "\(commonVariable.HOSTIP)/money/controller/ws/editUserPass"
    static var SETLOVERROLE = "\(commonVariable.HOSTIP)/money/controller/ws/setLoverRole"
    static var GETUSERACCOUNTINFO = "\(commonVariable.HOSTIP)/money/controller/ws/getUserAccountInfo"
    static var USERFEEDBACK = "\(commonVariable.HOSTIP)/money/controller/ws/userFeedback"
    static var SETUSERLOVERROLE = "\(commonVariable.HOSTIP)/money/controller/ws/setUserLoverRole"
    static var BOUNDFATHERACCOUNT = "\(commonVariable.HOSTIP)/money/controller/ws/boundFatherAccount"
    static var BOUNDMOTHERACCOUNT = "\(commonVariable.HOSTIP)/money/controller/ws/boundMotherAccount"
    static var BOUNDKIDACCOUNT = "\(commonVariable.HOSTIP)/money/controller/ws/boundKidAccount"
    static var BOUNDBFACCOUNT = "\(commonVariable.HOSTIP)/money/controller/ws/boundBFAccount"
    static var BOUNDGFACCOUNT = "\(commonVariable.HOSTIP)/money/controller/ws/boundGFAccount"
    static var GETCOMMONACCOUNT = "\(commonVariable.HOSTIP)/money/controller/ws/getCommonAccountDetailInfo"
    static var ACCOUNTBALANCEOPERATION = "\(commonVariable.HOSTIP)/money/controller/ws/accountBalanceOperation"
    static var GETLOVERACCOUNT = "\(commonVariable.HOSTIP)/money/controller/ws/getLoverAccountDetailInfo"
}